<?php
require_once "ProductVO.php";

class BlockVO extends ProductVO {
	public $_explicitType = "presstrack.products.BlockVO";
    
	function __construct($type) 
	{
		$pr->label = "блок";
		switch ($type) {
			case "magazine":			
				$pr->run = 1000;	
				$pr->size = "210x297";
				$pr->color = "K + K";
			break;
			
			case "catalog":
				$pr->run = 1000;	
				$pr->size = "210x297";
				$pr->color = "K + K";
			break;
		
			case "newspaper":
				$pr->run = 650;	
				$pr->size = "420x297";
				$pr->color = "C,M,Y,K + C,M,Y,K";
			break;
			
		case "book":
			$pr->run = 1000;	
			$pr->size = "210x297";
			$pr->color = "C,M,Y,K + 0";
		break;		
		}		
		$this->arOfProduct[] = $pr;
		$this->setTasks($type);
    }
	
	function setTasks($type)
	{
		switch ($type){
			case "magazine":
				$task_paper['label']	= 'бумага';
				$task_paper['value']	= 'название : офсет\rплотность : 80\rформат : 47x65\rдоля резки : 1/2\rзаказчика : set';
				$task_paper['section']	= 2;
				$task_paper['state']	= 1;
		
				$task_impos['label']	= 'спуск полос';
				$task_impos['value']	= 'спуск : 2x1';
				$task_impos['section']	= 3;
				$task_impos['state']	= 1;
		
				$task_ctp['label']		= 'вывод форм';
				$task_ctp['value']		= 'форм : 50';
				$task_ctp['section']	= 3;
				$task_ctp['state']		= 1;
		
				$task_press['label']	= 'печать';
				$task_press['value']	= 'машина : SM-52\rтираж : 25x1000\rна приладку : 25x200\rформат печати : 445x318\rкрасочность : 1+1';
				$task_press['section']	= 4;
				$task_press['state']	= 1;
		
				$task_fold['label']		= 'скрепление';
				$task_fold['value']		= 'тип : 2 скрепки\rстраниц : 100';
				$task_fold['section']	= 5;
				$task_fold['state']		= 1;
		
				$task_fit['label']		= 'подбор';
				$task_fit['value']		= 'вид : вкладкой';
				$task_fit['section']	= 5;
				$task_fit['state']		= 1;
				
				$this->arOfTasks[] = $task_paper;
				$this->arOfTasks[] = $task_impos;
				$this->arOfTasks[] = $task_ctp;
				$this->arOfTasks[] = $task_press;
				$this->arOfTasks[] = $task_fold;	
				$this->arOfTasks[] = $task_fit;				
			break;
		
			case "catalog":
				$task_paper['label']	= 'бумага';
				$task_paper['value']	= 'название : офсет\rплотность : 70\rформат : 64x90\rдоля резки : 1/4\rзаказчика : set';
				$task_paper['section']	= 2;
				$task_paper['state']	= 1;
		
				$task_impos['label']	= 'спуск полос';
				$task_impos['value']	= 'спуск : 2x1';
				$task_impos['section']	= 3;
				$task_impos['state']	= 1;
		
				$task_ctp['label']		= 'вывод форм';
				$task_ctp['value']		= 'форм : 50';
				$task_ctp['section']	= 3;
				$task_ctp['state']		= 1;
		
				$task_press['label']	= 'печать';
				$task_press['value']	= 'машина : SM-52\rтираж : 500\rна приладку : 100\rформат печати : 500x350\rкрасочность : 4+1';
				$task_press['section']	= 4;
				$task_press['state']	= 1;
		
				$task_cut['label']		= 'резка';
				$task_cut['value']		= 'тип : в формат';
				$task_cut['section']	= 5;
				$task_cut['state']		= 1;
				
				$task_fold['label']		= 'скрепление';
				$task_fold['value']		= 'тип : термоклей\rстраниц : 100';
				$task_fold['section']	= 5;
				$task_fold['state']		= 1;
				
				$this->arOfTasks[] = $task_paper;
				$this->arOfTasks[] = $task_impos;
				$this->arOfTasks[] = $task_ctp;
				$this->arOfTasks[] = $task_press;
				$this->arOfTasks[] = $task_cut;
				$this->arOfTasks[] = $task_fold;
			break;
			
			case "newspaper":
				$task_paper['label']	= 'бумага';
				$task_paper['value']	= 'название : офсет\rплотность : 80\rформат : 67x65\rдоля резки : 1/2\rзаказчика : set';
				$task_paper['section']	= 2;
				$task_paper['state']	= 1;
		
				$task_impos['label']	= 'спуск полос';
				$task_impos['value']	= 'спуск : 1x1';
				$task_impos['section']	= 3;
				$task_impos['state']	= 1;
		
				$task_ctp['label']		= 'вывод форм';
				$task_ctp['value']		= 'форм : 8';
				$task_ctp['section']	= 3;
				$task_ctp['state']		= 1;
		
				$task_press['label']	= 'печать';
				$task_press['value']	= 'машина : SM-52\rтираж : 650\rна приладку : 350\rформат печати : 465x323\rкрасочность : 4+4';
				$task_press['section']	= 4;
				$task_press['state']	= 1;
		
				$task_cut['label']		= 'резка';
				$task_cut['value']		= 'тип : в формат';
				$task_cut['section']	= 5;
				$task_cut['state']		= 1;
				
				$task_score['label']	= 'фальцовка';
				$task_score['value']	= 'вид : паралельная\rфальцев : 1\rформат в сложенном виде : 210х297';
				$task_score['section']	= 5;
				$task_score['state']	= 1;				
				
				$this->arOfTasks[] = $task_paper;
				$this->arOfTasks[] = $task_impos;
				$this->arOfTasks[] = $task_ctp;
				$this->arOfTasks[] = $task_press;
				$this->arOfTasks[] = $task_cut;
				$this->arOfTasks[] = $task_score;
			break;
		
			case "book":
				$task_paper['label']	= 'бумага';
				$task_paper['value']	= 'название : Art\rплотность : no set\rформат : set\rдоля резки : set\rзаказчика : set';
				$task_paper['section']	= 2;
				$task_paper['state']	= 1;
		
				$task_impos['label']	= 'спуск полос';
				$task_impos['value']	= 'спуск : 2x1';
				$task_impos['section']	= 3;
				$task_impos['state']	= 1;
		
				$task_ctp['label']		= 'вывод форм';
				$task_ctp['value']		= 'форм : 8';
				$task_ctp['section']	= 3;
				$task_ctp['state']		= 1;
		
				$task_press['label']	= 'печать';
				$task_press['value']	= 'машина : SM-52\rтираж : 500\rна приладку : 100\rформат печати : 500x350\rкрасочность : 4+1';
				$task_press['section']	= 4;
				$task_press['state']	= 1;
		
				$task_cut['label']		= 'резка';
				$task_cut['value']		= 'тип : в формат';
				$task_cut['section']	= 5;
				$task_cut['state']		= 1;
				
				$task_big['label']		= 'биговка';
				$task_big['value']		= 'бигов : 1';
				$task_big['section']	= 5;
				$task_big['state']		= 1;
				
				$this->arOfTasks[] = $task_paper;
				$this->arOfTasks[] = $task_impos;
				$this->arOfTasks[] = $task_ctp;
				$this->arOfTasks[] = $task_press;
				$this->arOfTasks[] = $task_cut;
				$this->arOfTasks[] = $task_big;
			break;
		}			
	}
}
?>